package com.qiyu.tech.pay;

import com.qiyu.core.cache.redis.annotation.CacheDataSource;
import com.qiyu.core.cache.redis.config.RedisEnvConstatns;
import com.qiyu.datasource.annotation.AppDataSource;
import com.qiyu.datasource.enums.DatasourceConfigEnum;
import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

/**
 * @Author linhao
 * @Date created in 8:56 上午 2021/3/29
 */
@SpringBootApplication(scanBasePackages = "com.qiyu.*")
@Slf4j
@AppDataSource(datasourceType = {DatasourceConfigEnum.CLOUD_DB_PAY}, defaultType = DatasourceConfigEnum.CLOUD_DB_PAY)
@CacheDataSource(cacheType = RedisEnvConstatns.RedisEnvEnum.LOCAL_DB)
public class WebApplication {

    public static void main(String[] args) {
        SpringApplication.run(WebApplication.class, args);
        log.info("====== WebApplication is started ======");
    }
}
